import request from '@/utils/request'


/**
 * 分页查询新闻
 * @param query
 * @returns {AxiosPromise}
 */
export function pageCusMessage(data) {
  return request({
    url: '/api/customer/messages/page',
    method: 'post',
    data: data
  })
}


/**
 * 详情接口
 * @param query
 * @returns {AxiosPromise}
 */
export function detailCusMessage(data) {
  return request({
    url: '/api/customer/messages/detail',
    method: 'post',
    data: data
  })
}


/**
 * 添加新闻
 * @param query
 * @returns {AxiosPromise}
 */
export function addCusMessage(data) {
  return request({
    url: '/api/customer/messages/add',
    method: 'post',
    data: data
  })
}


/**
 * 删除新闻
 * @param query
 * @returns {AxiosPromise}
 */
export function delCusMessage(data) {
  return request({
    url: '/api/customer/messages/delete',
    method: 'post',
    data: data
  })
}


/**
 * 更新新闻
 * @param query
 * @returns {AxiosPromise}
 */
export function updateCusMessage(data) {
  return request({
    url: '/api/customer/messages/update',
    method: 'post',
    data: data
  })
}

